﻿using System;
using System.Collections.Generic;
using System.Data;
using System.Data.SqlClient;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace _Ado.NET调用存储并使用OutPut
{
    class Program
    {
        static void Main(string[] args)
        {
            string procedureName = "pro_GetStudentCounts";


            string outString2 = SqlUtil.ExecuteNonQueryOutPut(WebConfigUtil.DefaultConnString, procedureName, "@counts");
            Console.WriteLine(outString2);



            SqlParameter para =
                new SqlParameter("@counts", SqlDbType.NVarChar, 128) { Direction = ParameterDirection.Output };
            string outString = SqlUtil.ExecuteNonQueryOutPutV2(WebConfigUtil.DefaultConnString, procedureName, "@counts", para);
            Console.WriteLine(outString);
            ;
            Console.ReadKey();
        }
    }
}
